package com.thd.springboottest.neo4j.controller;

import com.thd.springboottest.neo4j.dao.NeoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping("/neo4j")
public class Neo4jController {

    @Autowired
    private NeoService neoService;
    @ResponseBody
    @RequestMapping("/test")
    public String test(){
        System.out.println("haha");
        return "success";
    }

    @ResponseBody
    @RequestMapping("/save")
    public String save(){
        neoService.testSave();
        return "success";
    }
}
